<ion-header>
  <ion-toolbar class="orange-bar">
    <ion-buttons slot="start">
      <ion-button color="light" (click)="goBack()">
        <ion-icon name="ios-arrow-back"></ion-icon>
      </ion-button>
    </ion-buttons>
    <ion-title>{{data['title']}}({{data['bidNo']}})</ion-title>
  </ion-toolbar>
</ion-header>

<ion-content>

  <header padding-horizontal padding-top class="bg-orange">
    <div>
      <span style="font-size: 12px">投标金额(元)</span>
      <a float-right [routerLink]="['/auth/user-lend-bill', {investId: data['investId'], bidNo: data['bidNo'], title: data['title'], userRole: 1}]">
        <ion-text color="light">
          查看账单
          <ion-icon name="ios-arrow-forward" style="position: relative; top: 2px"></ion-icon>
        </ion-text>
      </a>
    </div>
    <h3>{{data.amount | number:'.2'}}</h3>
    <div>
      <span style="font-size: 12px">参考年回报率(%)</span>
      <a float-right (click)="openContract()">
        <ion-text color="light">
          合同信息
          <ion-icon name="ios-arrow-forward" style="position: relative; top: 2px"></ion-icon>
        </ion-text>
      </a>
    </div>
    <h3>{{data['apr'] | number:'.2'}}</h3>
  </header>

  <ion-list>
    <ion-item>
      <ion-label>
        <span>红包金额</span>
      </ion-label>
      <span slot="end">￥{{data['redPackAmount'] | number:'.2'}}</span>
    </ion-item>
    <ion-item>
      <ion-label>
        <span>加息利息</span>
      </ion-label>
      <span slot="end">￥{{data['coupInterest'] | number:'.2'}}</span>
    </ion-item>
    <ion-item>
      <ion-label>
        <span>期限</span>
      </ion-label>
      <span slot="end">{{data['period']}}{{data['periodUnit']}}</span>
    </ion-item>
    <ion-item>
      <ion-label>
        <span>还款方式</span>
      </ion-label>
      <span slot="end">{{data['repaymentType']}}</span>
    </ion-item>
    <ion-item>
      <ion-label>
        <span>放款时间</span>
      </ion-label>
      <span slot="end">{{data['time'] ? (data['time'] | date:'yyyy-MM-dd HH:mm:ss') : '---'}}</span>
    </ion-item>
    <ion-item>
      <ion-label>
        <span>状态</span>
      </ion-label>
      <span slot="end">{{data['statusStr']}}</span>
    </ion-item>
  </ion-list>

</ion-content>
